#{extends 'eventLayout.html' /}
#{if event}
    #{set title: event.nick /}


<h1>${event.nick}</h1>
<br/>
<br/>
<br/>

<form action="/${event.nick}/register" method="post" class="ym-form">
    <fieldset>
        <legend>Registro al evento <br/><br/></legend>
        <div class="ym-grid">
            <div class="ym-g50 ym-gl">
                <fieldset>
                    <legend>
                        Datos de la persona
                    </legend>
                    <div class="ym-fbox-select">
                        <label for="documentType">Tipo de documento</label>
                        <select name="documentType" id="documentType" size="1">
                            #{list items:documentsType, as: 'documentType'}
                                <option value="${documentType.id}">${documentType.name}</option>
                            #{/list}
                        </select>
                    </div>
                    <div class="ym-fbox-text">
                        <label for="code">Codigo del documento:</label>
                        <input name="code" id="code" ty1pe="text" value="${code}"/><br/>
                    </div>
                    <div class="ym-fbox-text">
                        <label for="name">Nombre:</label>
                        <input name="person.name" id="name" type="text"/><br/>
                    </div>
                    <div class="ym-fbox-text">
                        <label for="surname">Apellidos:</label>
                        <input name="person.surname" id="surname" type="text"/><br/>
                    </div>
                    <div class="ym-fbox-text">
                        <label for="email">Correo:</label>
                        <input name="person.email" id="email" type="text"/><br/>
                    </div>
                </fieldset>
            </div>
            <div class="ym-g50 ym-gr">
                <fieldset>
                    <legend>
                        Datos del evento
                    </legend>
                    <div>
                        Evento: <b>${event.nick}</b>
                    </div>
                    <div class="ym-fbox-text">
                        <label for="recibo">Numero de recibo:</label>
                        <input name="recibo" id="recibo" type="text"/><br/>
                    </div>
                </fieldset>
            </div>
        </div>
        <div class="ym-fbox-button">
            <input id="reset2" class="reset" type="reset" name="reset2" value="reset">
            <input type="submit" class="submit" value="Registrar"/>
        </div>
    </fieldset>
</form>

#{/if}